package main

import "fmt"

type Start interface {
	Start()
}
type Work interface {
	working()
}
type Usb interface {
	Start
	Work
	stop()
}
type smartPhone struct {
}

func (s *smartPhone) Start() {
	fmt.Println("手机开始充电")
}

func (s smartPhone) working() {
	fmt.Println("手机正在充电")
}

func (s smartPhone) stop() {
	fmt.Println("手机充电完成")
}

type camera struct {
}

func (c camera) Start() {
	fmt.Println("相机开始充电")
}

func (c camera) working() {
	fmt.Println("相机正在充电")
}

func (c camera) stop() {
	fmt.Println("相机充电完成")
}

type Video struct {
}

func (v Video) Start() {
	panic("implement me")
}

func (v Video) working() {
	panic("implement me")
}

func (v Video) stop() {
	panic("implement me")
}
func (s smartPhone) worked(usb Usb) {
	usb.Start()
	usb.working()
	usb.stop()
}
func main() {
	iPhone := &smartPhone{}
	/*canyon := camera{}*/
	/*iPhone.stop()
	canyon.Start()*/
	iPhone.worked(iPhone)

}
